/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package tp_imag.model;

/**
 *
 * @author Administrador
 */
public class RealceFilter extends Filter {

    private final static float params[]= {1f, -2f, 1f
                                    , -2f, 4f, -2f
                                    , 1f, -2f, 1f};

    public RealceFilter() {
        super();
    }

    public RealceFilter(int intensity) {
        super(intensity);
    }

    @Override
    public float[] getParameters(int intensity) {
        float[] values = copyParameters(getParameters());    

        //No se porque motivo si el valor de intensity es 1 el resultado del filtro es cualquier cosa
        if (intensity == 1) {
            intensity = 2;
        }
        values[4] = values[4] * intensity;
        return values;
    }

    public float[] getParameters() {
        return params;
    }

    public String getName() {
        return "Realce";
    }

}
